<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        // 存储缓存数据，BOM
        localStorage.setItem("age",18)
        // 读取缓存数据
        let str = localStorage.getItem("age")
        console.log(str);
        // 删除缓存数据(单个)
        // localStorage.removeItem("age")
        // 全部删除缓存数据
        // localStorage.clear()
    </script>
</body>
</html>